home *** CD-ROM | disk | FTP | other *** search
- ;*
- ;* $VER: copy.asm 1.2 (29 Mar 1996)(23 Mar 1996)
- ;*
- ;* memory.device - direct memory access
- ;*
- ;* (C) Copyright 1996 Marius Gröger
- ;* All Rights Reserved
- ;*
- ;* Inspired by z2ram device in Linux/68k/Amiga
- ;*
- ;* $HISTORY:
- ;*
- ;* 29 Mar 1996 : 001.002 : improved even more
- ;* 23 Mar 1996 : 001.001 : improved
- ;* 10 Mar 1996 : 001.000 : created
- ;*
- section "text",code
-
- ;----------------------------------------------------------------------------
-
-
- xdef _CopyMemWarp
-
-
- ;----------------------------------------------------------------------------
- ;
- ; NAME
- ; CopyMemWarp() - copy memory block assuming length = n * 128 Bytes
- ;
- ; SYNOPSIS
- ; void CopyMemWarp(VOID *src, VOID *dst, ULONG len)
- ; A0 A1 D0
- ;
- ; FUNCTION
- ; This is a very fast CopyMem() style function. It is assumed that length
- ; of the data to be copied is a multiple of 64 Bytes. The maximum
- ; length allowed is (2^22)-1 bytes.
- ;
- ; SEE ALSO
- ; exec.library/CopyMem(), exec.library/CopyMemQuick()
-
- _CopyMemWarp:
- asr.l #6,d0
- bra start
- copy:
- move.l (a0)+,(a1)+
- move.l (a0)+,(a1)+
- move.l (a0)+,(a1)+
- move.l (a0)+,(a1)+
- move.l (a0)+,(a1)+
- move.l (a0)+,(a1)+
- move.l (a0)+,(a1)+
- move.l (a0)+,(a1)+
- move.l (a0)+,(a1)+
- move.l (a0)+,(a1)+
- move.l (a0)+,(a1)+
- move.l (a0)+,(a1)+
- move.l (a0)+,(a1)+
- move.l (a0)+,(a1)+
- move.l (a0)+,(a1)+
- move.l (a0)+,(a1)+
- start:
- dbra d0,copy
- rts
-
-
- end
-